package cn.juque.lucenecandy.core.base;

import cn.juque.lucenecandy.core.annotation.Field;
import cn.juque.lucenecandy.core.annotation.Index;
import cn.juque.lucenecandy.core.enums.DataTypeEnum;
import lombok.Data;

/**
 * @author juque
 * @version 1.0.0
 * <ul>
 *     <li>BaseMessageEntity</li>
 * </ul>
 * @date 2024-01-02
 **/
@Data
@Index("_candy_data_sync_message")
public class BaseMessageEntity extends BaseEntity {

    /**
     * 实体类名
     */
    @Field(value = "class_name")
    private String className;

    /**
     * 操作类型
     */
    @Field(value = "sync_type")
    private String syncType;

    /**
     * 报文
     */
    @Field(value = "body")
    private String body;

    /**
     * 消息类型
     */
    @Field(value = "msg_type", type = DataTypeEnum.INT)
    private Integer msgType;

    /**
     * 时间戳
     */
    @Field(value = "timestamp", type = DataTypeEnum.LONG)
    private Long timestamp;
}
